<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>业务员业绩</title>
<%@ include file="/page/include.jsp" %>
<script type="text/javascript" src="<%=basePath%>/statics/js/jquery.select-1.3.6.js"></script>
</head>
</style>
<body>
<div class="pathinfo">
	<p><a href="#">业务员业绩</a></p>
	<input type="hidden" id="beginDate" value="${beginDate }" />
	<input type="hidden" id="endDate" value="${endDate }" />
	<input type="hidden" id="chartType" value="totalAmount" />
</div>
<div class="site_wrap13">
	<div class="site_wrap13_con">
    	<div class="hd">
        	<div class="title"><i></i>
        		<span>业绩Top10</span>
       		</div>
       		<div class="dd_nav2">
       			<p>
        			<a href="#" class="current" onclick="javascript: $('#chartType').val('totalAmount'); doLoadSalesmanAchievements('totalAmount');">订单金额</a>
        			<a href="#" onclick="javascript: $('#chartType').val('orderCount'); doLoadSalesmanAchievements('orderCount');">订单数量</a>
       			</p>
     		</div>
             <div class="search_dd">
            	<ul>
                	<li>
                		<select id="orgId" class="page_selector col-md-12" onchange="javascript: doLoadSalesmanAchievements($('#chartType').val());">
							<option value="">-全部-</option>
							<c:forEach items="${orgList }" var="org">
								<option value="${org.id }">${org.orgName }</option>
							</c:forEach>
						</select>
                    </li>
                    <li>
                         <div class="mydate datetime">
                         	<input type="text" id="searchSalesmanDate" name="searchSalesmanDate" class="form-control" onchange="javascript: doLoadSalesmanAchievements($('#chartType').val());">
                            <i class="glyphicon glyphicon-calendar fa fa-calendar"></i>
                        </div>
                    </li>
                    <li>
                         <a href="#" class="btn btn-default" onclick="javascript: doLoadSalesmanAchievements($('#chartType').val());">查询</a>
                    </li>
				</ul>
            </div>
        </div>
        <div class="bd">
        	<div class="col-md-8">
            	<div class="qy_pic" id="firstChartDiv" style="text-align: center;">
                	<div id="salesmanAchievementsMoneyDiv" style="width: 100%;height: 400px; margin: 0 auto;"></div>
                	<div id="salesmanAchievementsCountDiv" style="width: 100%;height: 400px; margin: 0 auto;display: none;"></div>
                </div>
            </div>
            <div class="col-md-4">
            	<table id="salesmanAchievementsTable"></table>
            </div>
        </div>
    </div>
</div>
<div class="site_wrap13">
	<div class="site_wrap13_con">
    	<div class="hd">
        	<div class="title"><i></i><span>销售比例</span></div>
             <div class="search_dd">
            	<ul>
                    <li>
                         <div class="mydate datetime">
                         	<input type="text" id="searchOrgDate" name="searchOrgDate" class="form-control" onchange="javascript: doLoadOrgSalesData();">
                            <i class="glyphicon glyphicon-calendar fa fa-calendar"></i>
                        </div>
                    </li>
                    <li>
                         <a href="#" class="btn btn-default" onclick="javascript: doLoadOrgSalesData();">查询</a>
                    </li>
				</ul>
            </div>
        </div>
        <div class="bd">
        	<div class="col-md-8">
            	<!-- 图表 -->
				<div class="qy_pic" style="text-align: center;">
                	<div id="orgSalesDiv" style="width: 100%;height: 400px; margin: 0 auto;"></div>
                </div>
            </div>
            <div class="col-md-4 col-sm-4 col-xs-4" style="height:400px;overflow: auto;">
				<table id="orgSalesTable"></table>
			</div>
        </div>
    </div>
</div>
<script src="${rootPath }/statics/plugins/echarts/echarts.min.js"></script>
<script src="${rootPath}/js/report/salesman_achievements.js"></script>
</body>
</html>